package com.hbnu.service;


@Service
public class UserService {

    @Resource(name="userDao")
    private UserDao userDao;

    public void setUserDao(UserDao userDao){
        this.userDao=userDao;
    }
    public void addUSeer(){

        System.out.println("add user by userService.....");
        userDao.addUser();
    }
    @Transactional
    public void account(){
        userDao.lessMoney();
        int i = 1/0;
        userDao.moreMoney();
    }

}
